package com.hopu.dy.service.impl;

import com.hopu.dy.mapper.DyMapper;
import com.hopu.dy.pojo.video;
import com.hopu.dy.service.IDyService;
import jakarta.annotation.Resource;
import org.springframework.stereotype.Service;

import java.util.List;

@Service //业务层声明，使得方法找到业务层
public class DyServiceImpl implements IDyService {
    @Resource
    private DyMapper dyMapper;


    @Override
    public List<video> get() {
        return dyMapper.select();
    }

    @Override
    public void insert(String title,String url) {
        dyMapper.insert(title,url);
    }
}
